package com.example.dockerci.controller;

import com.example.dockerci.entity.Application;
import com.example.dockerci.mapper.ApplicationMapper;
import java.util.List;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author CaiBinBin
 * @date 2021/7/30
 */
@RestController
public class FirstController {

  private final ApplicationMapper applicationMapper;

  public FirstController(ApplicationMapper applicationMapper) {
    this.applicationMapper = applicationMapper;
  }

  @GetMapping("getFirst")
  public Object getFirst() {
    List<Application> list = applicationMapper.selectList(null);
    System.out.println(list.size());
    return "Hello First";
  }
}
